package main

import (
	"github.com/EndlessCheng/codeforces-go/main/testutil"
	"testing"
)

func TestCF1158C(t *testing.T) {
	// just copy from website
	rawText := `
inputCopy
6
3
2 3 4
2
3 3
3
-1 -1 -1
3
3 4 -1
1
2
4
4 -1 4 5
outputCopy
1 2 3
2 1
2 1 3
-1
1
3 2 1 4
inputCopy
25
7
7 -1 5 7 7 7 8
8
9 8 5 7 9 9 -1 -1
7
7 5 -1 7 -1 7 -1
7
5 4 7 7 6 7 8
7
7 -1 6 -1 8 8 -1
7
8 5 4 8 6 8 8
7
2 8 4 5 8 8 -1
7
8 8 6 6 6 7 8
7
2 4 4 8 8 7 8
7
7 3 4 -1 6 -1 -1
8
9 4 5 9 8 9 8 -1
8
9 9 9 9 7 9 9 9
8
9 7 -1 5 6 9 9 -1
7
6 5 -1 5 8 8 -1
6
7 7 4 5 6 7
7
7 3 6 -1 -1 -1 -1
7
3 6 6 6 -1 7 8
8
9 4 6 5 8 -1 -1 9
8
9 9 9 6 7 -1 -1 9
7
3 8 5 6 -1 7 8
8
9 4 9 6 7 -1 -1 9
8
9 7 4 -1 -1 -1 9 -1
8
9 4 6 5 9 7 9 -1
6
6 6 -1 -1 -1 7
7
7 5 6 5 6 -1 -1
outputCopy
-1
-1
-1
-1
-1
-1
6 7 3 4 5 2 1 
7 6 3 2 1 4 5 
5 6 4 7 3 1 2 
6 1 2 3 4 5 7 
-1
-1
-1
-1
6 5 1 2 3 4 
6 3 4 1 2 5 7 
-1
-1
-1
-1
-1
8 6 2 3 4 5 7 1 
-1
5 4 1 2 3 6 
-1
-1
8 7 1 2 3 4 5 6 
6 5 3 1 2 4 7 
-1
-1
3 4 5 1 2 6 
-1
-1
8 5 2 3 1 4 6 7 
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
4 2 3 1 5 6 7 
-1
-1
8 7 3 4 1 2 5 6 
-1
-1
-1
-1
-1
-1
8 6 3 4 2 5 1 7 
-1
-1
-1
3 4 2 5 6 1 
-1
6 2 3 4 5 1 7 
-1
-1
-1
-1
6 7 2 3 1 4 5 
-1
7 5 3 2 4 1 6 `
	testutil.AssertEqualCase(t, rawText, 0, CF1158C)
}
